package com.orion.app.domain.entity;

import javax.persistence.Lob;
import javax.persistence.ManyToOne;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import org.springframework.roo.addon.javabean.RooJavaBean;
import org.springframework.roo.addon.jpa.activerecord.RooJpaActiveRecord;
import org.springframework.roo.addon.jpa.entity.RooJpaEntity;
import org.springframework.roo.addon.tostring.RooToString;
import org.springframework.roo.classpath.operations.jsr303.RooUploadedFile;

@RooJavaBean
@RooToString
@RooJpaActiveRecord
@RooJpaEntity(sequenceName = "emp_ext_cur_seq")
public class EmployeeExtraCurricularActivity {

    @NotNull
    @ManyToOne
    private EmployeeDetails employee;

    @Size(max = 100)
    private String activity;

    @Size(max = 100)
    private String rolePlayed;

    @Size(max = 100)
    private String since;

    private Boolean active;

    @Size(max = 200)
    private String achievements;

    @RooUploadedFile(contentType = "application/msword", autoUpload = true)
    @Lob
    private byte[] extraCurricularDocument;
}
